(function($f) {	$f.extend.custom("myPlugin1", function(self) {

	"use strict";
	
	// plugin info
	this.info = {
		title: "My Plugin 1",
		version: "0.0.1" // major.minor.build
	};

	// plugin events, subscriptions and handlers
	this.events = { 
		// a namespace for all the events in this plugin
		// when events are registered globally, this will be prefixed with
		// all specified events of this plugin
		// E.g., if the namespace is: AppName.Pages.Order
		// and event name is "Created"
		// the publicly registered event that will be AppName.Pages.Order.Created		
		namespace: "com.myCompany.myApp.Plugin1",

		// define one item for each event - at runtime this will be replaced by an event object
		// each item here is defined as:
		// <FriendlyEventName>: "ScopeQualifiedEventName"
		// a scope qualified event name must be unique across application 
		// each event object has three methods
		//	publish(args)
		// 	subscribe(handler)
		//	unsubscribe(handler)
		// ... event definitions goes here ...
		
		// event 1
		event1: "event1"
	};

	// custom handler defined at runtime
	this.onAppEvent2 = function(e) {
		$("#eventsLog").append("<p>" + self.info.title + " has handled '" + e.name + "' event of " + e.sender.info.title + ". Args: " + e.args[0].toString());
	};
}); }(fluid));
